package nl.haemers.form.rules 
{
	/**
	 * ...
	 * @author Jonathan Haemers
	 */
	public class BaseRule implements IRule
	{
		protected var _rule				:RegExp;
		
		//this is an Abstract Class I think ;)
		/** Public methods **/
		public function validate(value:String) : Boolean
		{
			return _rule.test(value);
		}
		
		/** Getters & Setters **/
		public function get rule() : RegExp
		{ 
			return _rule;
		}
		public function set rule(value:RegExp) : void 
		{
			_rule = value;
		}
	}

}